home *** CD-ROM | disk | FTP | other *** search
- Path: logica.co.uk!usenet
- From: Kevin Thomas <thomask@logica.com>
- Newsgroups: comp.lang.c++,comp.os.ms-windows.programmer.misc
- Subject: Exporting static data from 32-bit Windows DLLs
- Date: Wed, 21 Feb 1996 13:21:18 +0000
- Organization: Logica UK Ltd.
- Message-ID: <312B1C4E.4FF1@logica.com>
- NNTP-Posting-Host: 158.234.77.222
- Mime-Version: 1.0
- Content-Type: text/plain; charset=iso-8859-1
- Content-Transfer-Encoding: 8bit
- X-Mailer: Mozilla 2.0GoldB1 (Win95; I)
-
- Hi,
-
- IÆm trying to use Visual C++ (v4.0) to develop some 32-bit Windows DLLs.
- The DLLs must export class methods and static data members.
-
- IÆve successfully exported methods, but have a problem with exporting
- the static data. If I attempt to export the data with
- __declspec(dllexport) on the class or by providing an entry in the
- æEXPORTSÆ section of the .DEF file with the æDATAÆ keyword (as suggested
- by the documentation) then I get unresolved external errors attempting
- to link to it.
-
- If I provide an entry in the æEXPORTSÆ section of the .DEF file without
- the æDATAÆ keyword then the client program links to the DLL
- successfully, but at run-time the static data points at the wrong memory
- (thus making it full of garbage).
-
- Any ideas, anyone?
-
- Your help would be appreciated.
-
- Kevin Thomas.
-